﻿using SharpDX;

namespace MikadoShooter
{
    public class Collision
    {
        public int[] LineIndex { get; private set; }
        public bool IsAHit { get; private set; }
        public Vector2 Hit { get; private set; }
        public float? Distance { get; private set; }

        public Collision(int[] lineIndex, bool isAHit, Vector2 hit, float? distance)
        {
            Hit = hit;
            LineIndex = lineIndex;
            IsAHit = isAHit;
            Distance = distance;
        }

        public void Closer()
        {
            Hit = new Vector2(Hit.X, Hit.Y - 0.05f);
        }
    }
}